/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package ru.jSky.support.recoder;

import java.io.UnsupportedEncodingException;
import java.util.logging.Level;
import java.util.logging.Logger;

/**
 *
 * @author Rakev
 */
public class DoubleStringRecoder implements StringRecoder {

    private final String codePoint1;
    private final String codePoint2;

    public DoubleStringRecoder(String codePoint1, String codePoint2) {
        this.codePoint1 = codePoint1;
        this.codePoint2 = codePoint2;
    }

    @Override
    public String recode(String input) throws UnsupportedEncodingException {
            return new String(input.getBytes(codePoint1), codePoint2);
    }
}
